Hurd: fix port leak in TLS
authorRichard Braun <rbraun@sceen.net>
Tue, 4 Sep 2018 19:13:02 +0000 (20:13 +0100)
committerSamuel Thibault <sthibault@debian.org>
Tue, 4 Sep 2018 19:13:02 +0000 (20:13 +0100)
commit1570a9e35082217abbcd9791460e6d8cf0044885
tree791fde66fdcb4be8e8171e4e05b878c0358e3b1a
parente855b69117b5ae906aa17a0acb3cd03fb9df5b1e
Hurd: fix port leak in TLS

Depending on whether the thread is the main thread or not, the threading
library can have trouble determining whether the thread reference in the
TCB is valid. The simple solution is to let the threading library
initialize the TCB, and use a temporary reference when initializing TLS.

* sysdeps/mach/hurd/i386/tls.h (_hurd_tls_init): Use a temporary thread
reference.

Gbp-Pq: Topic hurd-i386
Gbp-Pq: Name git-tls_thread_leak.diff
sysdeps/mach/hurd/i386/tls.h